# Contributor: Francesco Colista <fcolista@alpinelinux.org>
# Maintainer:  Francesco Colista <fcolista@alpinelinux.org>
pkgname=mktorrent-borg
pkgver=0.9.9
pkgrel=0
pkgdesc="A handy tool for creating .torrent files"
url="http://borg.uu3.net/~borg/"
arch="all"
license="BSD-3-Clause"
makedepends="openssl-dev"
subpackages="$pkgname-doc"
source="ftp://borg.uu3.net/pub/unix/mktorrent/mktorrent-${pkgver}.tgz"

builddir="$srcdir/${pkgname/-borg/}"

build() {
	cd "$builddir"
	make
}

check() {
	cd "$builddir"
	./mktorrent --help > /dev/null
}

package() {
	cd "$builddir"
	install -D -m755 mktorrent $pkgdir/usr/bin/$pkgname
	install -D -m644 LICENSE $pkgdir/usr/share/licenses/$pkgname/LICENSE
}

sha512sums="ff702383c99d5c80b4433fb279968e1f19c6315216a2b74064ba57240ecd990b674195c035278c7e54801b77ab76fbb94667d8d7938d5ce2348faf015de27c5f  mktorrent-0.9.9.tgz"
